package com.smartao.core.license;

public class LicenseRegistry {
	private String productName;
	private String productVersion;
	private String serverID;
	private String organization;
	private int maxLicense;
	private String expireDate;
	private LicenseType licenseType;

	public String getProductName() {
		return productName;
	}

	public void setProductName(String productName) {
		this.productName = productName;
	}

	public String getProductVersion() {
		return productVersion;
	}

	public void setProductVersion(String productVersion) {
		this.productVersion = productVersion;
	}

	public String getServerID() {
		return serverID;
	}

	public void setServerID(String serverID) {
		this.serverID = serverID;
	}

	public String getOrganization() {
		return organization;
	}

	public void setOrganization(String organization) {
		this.organization = organization;
	}

	public int getMaxLicense() {
		return maxLicense;
	}

	public void setMaxLicense(int maxLicense) {
		this.maxLicense = maxLicense;
	}

	public String getExpireDate() {
		return expireDate;
	}

	public void setExpireDate(String expireDate) {
		this.expireDate = expireDate;
	}

	public LicenseType getLicenseType() {
		return licenseType;
	}

	public void setLicenseType(LicenseType licenseType) {
		this.licenseType = licenseType;
	}

	@Override
	public String toString() {
		StringBuffer buffer = new StringBuffer("<license>");
		buffer.append("<productName>").append(productName).append("</productName>");
		buffer.append("<productVersion>").append(productVersion).append("</productVersion>");
		buffer.append("<serverID>").append(serverID).append("</serverID>");
		buffer.append("<organization>").append(organization).append("</organization>");
		buffer.append("<maxLicense>").append(maxLicense).append("</maxLicense>");
		buffer.append("<expireDate>").append(expireDate).append("</expireDate>");
		buffer.append("<licenseType>").append(licenseType).append("</licenseType>");
		buffer.append("</license>");
		return buffer.toString();
	}
}
